package com.share.device.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.util.Date;

@Data
@Schema(description = "人员")
public class Personnel {

    private static final long serialVersionUID = 1L;

    /** 人员id */
    @Schema(description = "人员id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /** 人员名称 */
    @Schema(description = "人员名称")
    @NotBlank(message = "人员名称不能为空")
    private String personnelName;

    /** 区域id */
    @Schema(description = "区域id")
    @NotNull(message = "区域id不能为空")
    private Long areaId;

    /** 角色id */
    @Schema(description = "角色id")
    @NotNull(message = "角色id不能为空")
    private Integer roleId;

    /** 联系电话 */
    @Schema(description = "联系电话")
    @NotBlank(message = "联系电话不能为空")
    private String phone;

    /** 头像 */
    @Schema(description = "头像")
    private String avatar;

    /** 状态 0启用 1不启用 */
    @Schema(description = "状态 0启用 1不启用")
    private Integer state;

    /** 创建时间 */
    @Schema(description = "创建时间")
    private Date createTime;
}